﻿namespace Bzure.Mvc.Views
{
    using System.CodeDom;
    using System.Web.UI;

    internal sealed class BzureViewMasterPageControlBuilder : FileLevelMasterPageControlBuilder
    {

        // Methods
        public override void ProcessGeneratedCode(CodeCompileUnit codeCompileUnit, CodeTypeDeclaration baseType, CodeTypeDeclaration derivedType, CodeMemberMethod buildMethod, CodeMemberMethod dataBindingMethod)
        {
            if (!string.IsNullOrWhiteSpace(this.Inherits))
            {
                derivedType.BaseTypes[0] = new CodeTypeReference(this.Inherits);
            }
        }

        // Properties
        public string Inherits { get; set; }

    }
}